#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int ans=0;

void solve(int index,int right)//答题数，正确数
{
	if(right==10)
		return;
	if(right==7)
		ans++;
	if(index==30)
		return;
	solve(index+1,right+1);
	solve(index+1,0);
}
int main(int argc, char** argv) {
	solve(1,0);//答了一题答错了
	solve(1,1);//答了一题答错了
	cout<<ans<<endl;
	return 0;
}
